package top.iflyoung.cim.biz.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Param;
import top.iflyoung.cim.biz.entity.ChatRouteInfo;

import java.util.List;

/**
 * @author liguiyang
 * @description
 * @sine 1.8
 * @date 2021/9/418:23
 **/
public interface ChatRouteInfoMapper extends BaseMapper<ChatRouteInfo> {
    /**
     * 根据用户ID删除信息
     * @param userId
     * @return
     */
    long deleteByUserId(@Param("userId") Long userId);

    /**
     * 根据用户ID查询出用户连接的服务器
     * @param userId
     * @return
     */
    List<ChatRouteInfo> queryByUserId(@Param("userId") Long userId);
}
